package com.yh.services.impl;

import com.yh.dao.MessageMapper;
import com.yh.entity.Message;
import com.yh.services.IMessageService;
import com.yh.util.SqlSessionFactoryUtil;
import org.apache.ibatis.session.SqlSession;

public class MessageServiceImpl implements IMessageService {
    SqlSession sqlsession = SqlSessionFactoryUtil.getSqlsession();
    MessageMapper mapper = sqlsession.getMapper(MessageMapper.class);
    @Override
    public int addMessage(Message message) {

        return mapper.addMessage(message);
    }
}
